package com.xiaoyun.repository;

import com.xiaoyun.pojo.PayOrders;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

@Repository
public interface PayOrdersRepository extends JpaRepository<PayOrders, String> {

    PayOrders findByMerchantOrderIdAndMerchantUserId(String merchantUserId,
                                                     String merchantOrderId);

    PayOrders findByMerchantUserIdAndMerchantOrderIdAndPayStatus(String merchantUserId,
                                                                 String merchantOrderId,
                                                                 Integer orderStatus);

    PayOrders findByMerchantOrderId(String merchantOrderId);
}
